
#ifndef _MEMBER_BRENDER_H_
#define _MEMBER_BRENDER_H_

#include <BRender>
#include <BLight>
#include <BCamera>
#include "IGLState.h"

#define render_member(render)	((member_BRender*)((BRender*)render)->_ptr)

namespace BWE
{
	class member_BRender : public IGLState
	{
	public:
		member_BRender(BRender* render);
		~member_BRender();

		void useLights(const BBox& box);

		BRender*		boss;
		BColor			color;
		bool			lighting;
		bool			normalize;
		bool			cullback;
		bool			depthTest;
		float			depthOffset;
		bool			pointSmooth;
		float			pointSize;
		bool			lineSmooth;
		float			lineWidth;
		GLint			lineStipple;
		int				polyMode;
		bool			polySmooth;
		BUInt			tbos[10];
		BMatrix			matrix;

		const BCamera*		camera;
		const BLight*		light;
		const BNode*		node;
		const BShape*		shape;
		const BLightSet*	lights;
		const BProgram*		program;
		const BMaterial*	material;
	};
}

#endif
